package TemplateMethod;

public class Client {
    public static void main(String[] args) {
        AbstractDefiniteIntegral[] x = new AbstractDefiniteIntegral[2];
        x[0] = new DefiniteIntegralX(0,20,1000);
        x[1] = new DefiniteIntegralLog(2.71,20,1000);

        for(int i = 0; i < 2; ++i)
        {
            System.out.println(x[i].calDefiniteIntegral());
        }
    }
}
